package org.cn.osiris.user.domain;


import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.cn.osiris.basic.domain.BaseDomain;

import java.util.Date;

/**
 * 实体类：
 */
@Data
@AllArgsConstructor
@NoArgsConstructor
public class User extends BaseDomain {

    private String username;
    private String phone;
    private String email;
    /**
     * 盐值
     */
    private String salt;
    /**
     * 密码，md5加密加盐
     */
    private String password;
    /**
     * 员工状态 - 1启用，0禁用
     *
     * 邮箱注册默认禁用
     * 手机注册需要设置
     */
    private Integer state;
    private Integer age;
    private Date createtime = new Date();
    private String headImg;
    private Long logininfoId;

    public User(Long id, String username) {
        super(id);
        this.username = username;
    }

    public User(String username) {
        this.username = username;
    }
}
